package com.bc.service.deal.Btc100;

import java.io.IOException;

import android.content.Context;

import com.bc.service.GenericService;
import com.bc.service.SimpleRequestListener;
import com.bc.service.deal.BtcCategory;
import com.bc.service.deal.ServiceCategory;
import com.bc.service.deal.QJLfutures.QJLfuturesResponse.Ticker;

public class Btc100Service extends GenericService<Btc100Request, Btc100Response> implements ServiceCategory{

	public Btc100Service(Context context) {
		super(context);
	}
	
	public Ticker getBtc100Tickers() {
		return mResponse == null ? null : mResponse.ticker;
	}
	
	@Override
	protected void onRequest(int requestCode, Btc100Request request) {
		
	}

	@Override
	protected void onResponse(int requestCode, Btc100Request request,
			Btc100Response response) throws IOException {
		
	}

	@Override
	public void loadBtcData(SimpleRequestListener listener) {
		setRequest(new Btc100Request());
		request(REQUEST_CODE_LOAD, listener);
	}

	@Override
	public BtcCategory getServieResponse() {
		return mResponse;
	}

	@Override
	public void cancelLoading() {
	    super.cancel();
	}

}
